﻿using System;
using System.Collections;
using System.ComponentModel;
using System.Web.UI.Design;

namespace MyLib.Web.UI {
	/// <summary>
	/// 
	/// </summary>
	public class MyPanelContainerDesigner : ContainerControlDesigner {
		/// <summary>
		/// 
		/// </summary>
		/// <param name="component"></param>
		public override void Initialize(IComponent component) {
			if (!(component is MyPanel))
				throw new ArgumentException(string.Format("Argument must be of type: {0}", typeof(MyPanel)));

			base.Initialize(component);
		}

		/// <summary>
		/// 
		/// </summary>
		/// <param name="styleAttributes"></param>
		protected override void AddDesignTimeCssAttributes(IDictionary styleAttributes) {
			base.AddDesignTimeCssAttributes(styleAttributes);
		} // end of AddDesignTimeCssAttributes.

		/// <summary>
		/// 
		/// </summary>
		protected override bool UsePreviewControl {
			get {
				return true;
			}
		}
	} // end of MyPanelContainerDesigner.
}
